
import { v4 as uuidv4 } from 'uuid';
export function GetUserTempId(){
    let userTempId = localStorage.getItem("userTempId")

    if(userTempId){
        return userTempId
    }else{
        let newUserTempId = uuidv4()
        localStorage.setItem("userTempId",newUserTempId)
        return newUserTempId
    }
}


export function saveToken(token){
    localStorage.setItem("token",token)
}

export function getToken(){
    return  localStorage.getItem("token")
}

export function deleteToken(){
    return  localStorage.removeItem("token")
}